package cn.lingyangwl.agile.member.manager;

import cn.lingyangwl.agile.member.mapper.MemberUserMapper;
import cn.lingyangwl.agile.member.model.entity.MemberUser;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Repository;

/**
 * 会员用户 仓储层
 *
 * @author shenguangyang
 */
@Slf4j
@Repository
public class MemberUserManager extends ServiceImpl<MemberUserMapper, MemberUser>
    implements IService<MemberUser> {

    public MemberUser getByPhone(String phone) {
        return this.getOne(MemberUser.lqw().eq(MemberUser::getPhone, phone));
    }
}
